<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
	<title></title>
	<script src="http://127.0.0.1/mogujie/Static/Js/jquery-1.8.2.min.js" type="text/javascript" charset="utf-8"></script>
	<link rel="stylesheet" type="text/css" href="http://127.0.0.1/mogujie/Static/hdjs/hdjs.css"/>
    <script src="http://127.0.0.1/mogujie/Static/hdjs/hdjs.min.js" type="text/javascript" charset="utf-8"></script>
	<link rel="stylesheet" href="http://127.0.0.1/mogujie/Static/admin/bootstrap/css/bootstrap.min.css" />
	<!--<link rel="stylesheet" href="http://127.0.0.1/mogujie/Application/Admin/View/Public/index/css/common.css" />-->
	
	<style type="text/css">
		body{
			margin-bottom: 100px;
		}
	</style>
</head>
<body>
	<div class="container-fluid">
	<div class="row-fluid">
	<div class="span12">

	<table class="table table-bordered table-hover">
		<tr>
			<th>ID</th>
			<th>订单号</th>
			<th>收货人</th>
			<th>收货地址</th>
			<th>手机号</th>
			<th>价格总计</th>
			<th>订单生成时间</th>
			<th>订单状态</th>
			<!--<th>备注说明</th>-->
			<th>操作</th>
		</tr>

		<?php foreach ($orderData as $k=>$v){?>
		      <?php if($v['status'] !=='已完成'){ ?>
				<tr class="info">
					<td><?php echo $v['oid'];?></td>
					<td><?php echo $v['number'];?></td>
					<td><?php echo $v['consignee'];?></td>
					<td><?php echo $v['address'];?></td>
					<td><?php echo $v['mobile'];?></td>
					<td>￥<?php echo $v['total'];?>.00</td>
					<td width="88px"><?php echo date('Y-m-d H:i:s',$v['time']);?></td>
					<td><?php echo $v['status'];?></td>
					<!--<td><?php echo $v['remark'];?></td>-->
					
					<td width="138px">
						<a href="<?php echo U('OrderList/index', array('oid' => $v['oid']));?>" class="hd-btn hd-btn-success hd-btn-xm">详细列表</a>
						    <?php if($v['status']=='已付款'){ ?>
						   <a href="<?php echo U('FinishOrder/sendOutGoods', array('oid' => $v['oid']));?>" class="hd-btn hd-btn-success hd-btn-xm">发货</a>
						<?php } ?>
					</td>
				</tr>
			<?php } ?>
			
		<?php }?>
	</table>

	</div>
	</div>
	</div>
	
<script type="text/javascript">
   function hd_modal_del(gid) {
    hd_modal({
        width: 220,//宽度
        height: 150,//高度
        title: '你确认删除吗？',//标题
        content: '',//提示信息
        button: true,//显示按钮
        button_success: "确定",//确定按钮文字
        button_cancel: "取消",//关闭按钮文字
        timeout: 0,//自动关闭时间 0：不自动关闭
        shade: true,//背景遮罩
        shadeOpacity: 0.5,//背景透明度
        success: function () {//点击确定后的事件
			location.href = "http://127.0.0.1/mogujie/index.php/Admin/Order" + '&a=del&gid=' + gid;
        },
        cancel: function () {//点击关闭后的事件
			
        }
    });
}
</script>
	
</body>
</html>